﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data;
using System.Data.SqlClient;
using DTO;

namespace DAO
{
    public class MatKhauDAO
    {
        public DataTable Somatkhau()
        {
            Data a = new Data();
            DataTable d = new DataTable();
            string sql = "select MatKhau from ThamSo";
            d = a.ExecuteQuery(sql);
            return d;
        }
        public void thaydoimatkhau(MatKhauDTO DTO)
        {
            Data a = new Data();
            string sql = "update ThamSo set MatKhau = '"+DTO.Matkhau+"'" ;
            a.ExecuteNonQuery(sql);
     
        }
    }
}
